package com.itheima.ydd.controller;

import com.itheima.ydd.common.R;
import com.itheima.ydd.common.ResultData;
import com.itheima.ydd.service.ISysConfigService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/sys_config")
@CrossOrigin  //启用CORS跨域支持
@Slf4j
public class SysConfigController {


    @Autowired
    private ISysConfigService sysConfigService;  //系统配置展示

    //系统配置类

    @GetMapping("/all")
    public R getAll(){
        return sysConfigService.getAll();
    }
}
